<extend name="layout/admin" />
<block name="title">分类列表</block>
<block name="content">
<div class="row">
	<div class="col-lg-12">
		<div class="panel panel-default">
			<div class="panel-heading">分类列表</div>
			<div class="panel-body">
				<div class="bootstrap-table">
					<div class="fixed-table-container">
						<div class="fixed-table-header"><table></table></div>
						<div class="fixed-table-body">
							<div class="fixed-table-loading" style="top: 37px; display: none;">Loading, please wait…</div>
							<table data-toggle="table" data-url="tables/data1.json" data-show-refresh="true" data-show-toggle="true" data-show-columns="true" data-search="true" data-select-item-name="toolbar1" data-pagination="true" data-sort-name="name" data-sort-order="desc" class="table table-hover">
							    <thead>
							    	<tr>
							    		<th style="">
							    			<div class="th-inner sortable">分类名称</div>
							    		</th>
							    		<th style="">
							    			<div class="th-inner sortable">父级分类</div><div class="fht-cell"></div>
							    		</th>
							    		<th style="">
							    			<div class="th-inner sortable">操作</div><div class="fht-cell"></div>
							    		</th>
							    	</tr>
							    </thead>
								<tbody>
									<foreach name="res" item="vo" >
										<tr data-index="0">
								            <td>{$vo['name']}</td>
								            <td>{$vo['pid']|getCateName}</td>
								            <td>
												<a href="{:U('admin/cate/edit',array('id'=>$vo['id']))}">重命名</a>&nbsp;|&nbsp;
								            	<a href="{:U('admin/cate/delete',array('id'=>$vo['id']))}">删除</a>&nbsp;|&nbsp;
												<a href="{:U('admin/cate/add',array('pid'=>$vo['id']))}">添加子分类</a>
											</td>
										</tr>
									</foreach>
								</tbody>
							</table>
						</div>
						<div class="fixed-table-pagination">
							<div class="pull-right pagination">
								<ul class="pagination">
									<li class="page-number"><a href="javascript:void(0)">{$page}</a></li>
								</ul>
							</div>
						</div>
					</div>
				</div>
				<div class="clearfix"></div>
			</div>
		</div>
	</div>
</div>
</block>